package com.file.system.entity.basic;

import com.alibaba.fastjson2.annotation.JSONField;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.datatype.jsr310.deser.LocalDateTimeDeserializer;
import com.fasterxml.jackson.datatype.jsr310.ser.LocalDateTimeSerializer;
import lombok.Data;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.time.LocalDateTime;

;

/**
 * 基本信息
 *
 * @author jch
 */
@Data
@Accessors(chain = true)
public class WebBasic implements Serializable {
    /**
     * 创建人
     *
     * @ignore
     * @mock
     */
    private Long createBy;
    /**
     * 修改人
     *
     * @ignore
     * @mock
     */
    private Long updateBy;
    /**
     * 删除人
     *
     * @ignore
     * @mock
     */
    private Long deleteBy;
    /**
     * 创建时间
     *
     * @ignore
     */
    @JsonSerialize(using = LocalDateTimeSerializer.class)
    @JsonDeserialize(using = LocalDateTimeDeserializer.class)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime createTime;
    /**
     * 修改时间
     *
     * @ignore
     */
    @JsonSerialize(using = LocalDateTimeSerializer.class)
    @JsonDeserialize(using = LocalDateTimeDeserializer.class)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime updateTime;
    /**
     * 删除时间
     *
     * @ignore
     */
    @JsonSerialize(using = LocalDateTimeSerializer.class)
    @JsonDeserialize(using = LocalDateTimeDeserializer.class)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime deleteTime;
    /**
     * 创建人姓名
     *
     * @ignore
     * @mock jch
     */
    private String createName;
    /**
     * 修改人姓名
     *
     * @ignore
     * @mock jch
     */
    private String updateName;
    /**
     * 删除人姓名
     *
     * @ignore
     * @mock jch
     */
    private String deleteName;
    /**
     * 是否删除 0否1是
     *
     * @ignore
     * @mock 0
     */
    private Integer isDel;
    /**
     * 分表使用
     */
    @JSONField(serialize = false)
    @JsonIgnore
    private Integer tableNum;
}
